-
Notifications
You must be signed in to change notification settings - Fork 197
feat: contribute aws eks resource detector #1479
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
feat: contribute aws eks resource detector #1479
Conversation
cba8900
to
ee6ba6f
Compare
17b1826
to
8787fea
Compare
dc4076c
to
eacac6a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this looks great! thanks @yiyuan-he
one comment about the error handlers vs. logs
I was wrong about the error handlers! Failure to detect should not be an error log.
See #1538
it 'returns an empty resource with unknown detector' do | ||
assert_detection_result([:unknown]) | ||
end | ||
|
||
it 'returns an empty resource with multiple detectors when all fail' do | ||
assert_detection_result(%i[ec2 ecs unknown]) | ||
assert_detection_result(%i[ec2 ecs eks lambda unknown]) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
good catch!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah okay no worries. In that case, i'll keep this EKS detector as is since it's already using debug logs and update the other detectors. Left a comment in that issue as well.
EDIT: Meant to leave this reply in the other thread.
request = case method.upcase | ||
when 'GET' | ||
Net::HTTP::Get.new(uri) | ||
when 'POST' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
am I missing something here. Is there a case where POST is used?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for pointing this out Ariel - POST should not be used. Pushed a commit to clean up this dead code.
What does this pull request do?
Adds functionality for AWS EKS resource detection in AWS resource detector gem. It is similar to the implementation for Python.
This feature is branched off PR.
Related issues
#34